PUBLIC_PATH=../../../../public
LIB2_PATH=../../../../lib2-64
SPATIAL_PATH=../../../../app/search/webgis/lib/spatial-base
TYPE_PATH=../../../../app/search/webgis/lib/type-factory

INCLUDEDIR= -I$(PUBLIC_PATH)/sign/output/include \
	-I$(LIB2_PATH)/bsl/include \
	-I$(SPATIAL_PATH)/output \
	-I$(TYPE_PATH)/output

LIBDIR= -L$(TYPE_PATH)/output -ltype_factory \
	-L$(LIB2_PATH)/bsl/lib -lbsl \
	-L$(PUBLIC_PATH)/sign/output/lib -luln_sign \
	-L$(SPATIAL_PATH)/output  \
	-L$(TYPE_PATH)/output -ltype_factory \
	-luuid

TARGET = guid2uid

CPPFLAGS = -g -W -Wall -pipe $(INCLUDEDIR)

OBJECTS = $(patsubst %.cpp,%.o, $(wildcard *.cpp))

all: $(TARGET) $(TARGET_TEST) output

$(TARGET) : $(OBJECTS)
	$(CXX) -o $@ $^ $(INCLUDEDIR) $(LIBDIR)

.PHONY : output clean

clean :
	rm -f *.o $(TARGET)
	rm -rf output

output:
	rm -rf output
	mkdir -p output
	cp $(TARGET) ./output

